package com.cicc.beergamevirtualsimulationsystem.model.room.req;

import com.cicc.beergamevirtualsimulationsystem.annotation.EnumValid;
import com.cicc.beergamevirtualsimulationsystem.common.constant.ParameterConstant;
import com.cicc.beergamevirtualsimulationsystem.common.constant.RoomConstant;
import com.cicc.beergamevirtualsimulationsystem.common.enums.parameterEnum.DemandCurveEnum;
import com.cicc.beergamevirtualsimulationsystem.common.enums.parameterEnum.RoleAllocationModeEnum;
import com.cicc.beergamevirtualsimulationsystem.model.parameter.req.ParameterCreatorReq;
import com.cicc.beergamevirtualsimulationsystem.model.userType.RoleTypeReq;
import jakarta.validation.Valid;
import jakarta.validation.constraints.Min;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import lombok.Data;

import java.util.List;

/**
 * 创建房间
 */
@Data
public class CreateRoomReq {


    /**
     * 总人数
     */
    @Min(value = RoomConstant.TOTAL_PEOPLE_NUM, message = RoomConstant.TOTAL_PEOPLE_NUM_ERROR)
    private Integer totalPeopleNum;

    /**
     * 需求曲线
     */
    @EnumValid(enumClass = DemandCurveEnum.class, message = ParameterConstant.DEMAND_CURVE_ERROR)
    private Integer demandCurve;

    /**
     * 角色分配模式
     */
    @EnumValid(enumClass = RoleAllocationModeEnum.class, message = ParameterConstant.ROLE_ALLOCATION_MODE_ERROR)
    private Integer roleAllocationMode;

    /**
     * 周期数
     */
    private Integer cycles;

    /**
     * 到货周期数
     */
    private Integer deliveryCycle;

    /**
     * 对局时间
     */
    private Integer gameTime;

    /**
     * 级别
     */
    private Integer level;
    /**
     * 角色类型表
     */
    @Valid
    private List<RoleTypeReq> roleTypeList;

}
